#include<bits/stdc++.h>
#define int long long
using namespace std;
inline int read(){
	int x=0;bool f=0;char ch=getchar();
	while(ch<'0'||ch>'9')f^=(ch=='-'),ch=getchar();
	while('0'<=ch&&ch<='9')x=(x<<1)+(x<<3)+(ch^48),ch=getchar();
	return f?-x:x;
}
const int Maxn=2e5+5;
int n,a[Maxn],sum[Maxn];
int f[Maxn];
int q;
signed main(){
	freopen("pockets.in","r",stdin);
	freopen("pockets.out","w",stdout);
	n=read();
	for(int i=1;i<n;i++)a[i]=read(),sum[i]=sum[i-1]+a[i];
	q=read();
	while(q--){
		a[n]=read();
		if(a[n]>sum[n-1]){
			printf("%lld\n",a[n]+a[1]-(sum[n-1]-sum[1]));
			continue;
		}f[n]=a[n];
		int mx=f[n]-sum[n-1];
		for(int i=n-1;i>1;i--){
			f[i]=-sum[i-1]-mx;
			mx=max(mx,f[i]-sum[i-1]);
		}printf("%lld\n",a[1]-f[2]);
	}
	return 0;
}
/*
10
3 1 4 1 5 9 2 6 5
6
3
6
9
180
15
31
*/
